<template>
    <!-- 页面全局配置 -->
    <view class="pageconfig" :style="{'padding-top':StatusBar + 'px'}">
        <!--vuetop-->
        <view class="   gongge1 1   response ">
            <view class=" cu-list grid col-4 no-border">
                <view     @click="nav(index1)"  class="cu-item padding-xs " v-for="(item, index1) in label1List" :key="index1">
                    <view>
                        <image v-if="item.imgtype !=2" :src="item.pic" class="round" mode="heightFix" style="width: auto;height:70rpx;line-height:0rpx"></image>
                        <view v-if="item.imgtype ==2" :class="['' + item.iconname,'text-' + item.iconcolor]" style="font-size: 70rpx;margin-top: 0rpx;"></view>
                    </view>
                    <text style="font-size: unset;color: unset;margin-top:4rpx;">{{item.name}}</text>
                </view>
            </view>
        </view>


        <!--vuebottom-->
    </view>
</template>


<script>
    import Vue from 'vue'
    export default {
        data() {
            return {
                StatusBar: 0,


                label1List: [{
                    "name": "开始答题",
                    "imgtype": 2,
                    "iconcolor": "red",
                    "apiimg": "",
                    "apiname": "",
                    "event": "",
                    "iconname": "cuIcon-edit",
                    "pic": "",
                    "url": "/pages/users/user_address_list/index"
                }, {
                    "name": "答题记录",
                    "imgtype": 2,
                    "iconcolor": "red",
                    "apiimg": "",
                    "apiname": "",
                    "event": "",
                    "iconname": "cuIcon-more",
                    "pic": "https://shitangsys.cntdh.net//uploads/store/comment/20220426/a0e089eae12fefc254284f6bad3b8a03.png",
                    "url": "/pages/users/user_money/index"
                }],
                /**vuejs**/


            };
        },
        onLoad() {
            this.getsysinfo();


        },
        methods: {
			nav(index){
				switch (index) {
					case 0:
						uni.navigateTo({
							url: "./dati_list"
						});
						break;
					case 1:
						uni.navigateTo({
							url: "./dati_log"
						});
						break;
					default:
						// 处理其他情况，如果有的话
						break;
				}
			},
            //获取顶部状态栏的高度
            getsysinfo() {
                let that = this;
                uni.getSystemInfo({
                    success: function(e) {
                        that.StatusBar = e.statusBarHeight;
                        // #ifdef H5
                        that.StatusBar = 0;
                        // #endif


                    }
                })

            },



            /**
             *          $vuetag = "";
             *          $vuecss = "";
             *          $vuejs = "";
             *
             */

            //获取数据

        }
    }
</script>

<style lang="less">
    /**
 *
 此处必须引用colorui样式,并放入根目录，css样式可以这样写
	@import "colorui/main.css";
	@import "colorui/icon.css";

 如需要引用colorui到全局，
 需要在App.vue 引入
 	@import "colorui/main.css";
	@import "colorui/icon.css";
 *
 */




    /**本页全局配置的代码**/
    .pageconfig {
        width: 100%;
        overflow: hidden;
        overflow-y: scroll;
        height: 100vh;
    }



    /**pagedomcss**/


    .gongge1 {
        width: 100%;
    }
</style>